import java.util.ArrayList;
import java.util.Collections;

public class Test1 {
    public static void main(String[] args) {
        //随机点名其
        //1.定义集合
        ArrayList<String> list = new ArrayList<>();
        //2.添加元素
        Collections.addAll(list,"小明","小红","小李","小芳");
        //3.随机点名
        //打乱
        Collections.shuffle(list);
        String name = list.get(0);
        System.out.println(name);
    }
}
